package vo;

public class Goods {
    public static final int SHELVE = 1, OFF_SHELVE = 0, ALL = 2;
    private int id, state;//state 0对应OFF_SHELVE代表下架,1对应shelve常量代表该菜品上架,2代表所有菜品
    private String name, description, image = "default.jpg";
    private float price;

    /*新增属性,salesQuantity指 销售数量.
                newItem指 新菜品

                */
    private int salesQuantity;
    private boolean newItem=true;

    @Override
    public String toString() {
        return "Goods{" +
                "id=" + id +
                ", state=" + state +
                ", name='" + name + '\'' +
                ", description='" + description + '\'' +
                ", image='" + image + '\'' +
                ", price=" + price +
                ", salesQuantity=" + salesQuantity +
                ", newItem=" + newItem +
                '}';
    }

    /*不知道有什么用*/

    public static int getSHELVE() {
        return SHELVE;
    }

    public static int getOffShelve() {
        return OFF_SHELVE;
    }

    public static int getALL() {
        return ALL;
    }

    public int getSalesQuantity() {
        return salesQuantity;
    }

    public void setSalesQuantity(int salesQuantity) {
        this.salesQuantity = salesQuantity;
    }

    public boolean isNewItem() {
        return newItem;
    }

    public void setNewItem(boolean newItem) {
        this.newItem = newItem;
    }

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public float getPrice() {
        return price;
    }

    public void setPrice(float price) {
        this.price = price;
    }
}
